import type { IModalConfig } from '@/global/types'

export const roleModalEditAndAddConfig: IModalConfig = {
  type: 'dialog',
  layout: {
    title: '填写类型数据',
    width: '30%',
    showClose: true, // 是否显示右上角关闭图标
    closeOnClick: true // 点击遮罩层是否能关闭对话框
  },
  form: {
    layout: {
      isShowBtns: false,
      labelWidth: '80px',
      size: 'default'
    },
    items: [
      {
        type: 'input',
        prop: 'typeName',
        span: 24,
        label: '类型名',
        placeholder: '请输入类型名'
      }
    ],
    rules: {
      typeName: [
        {
          message: '类型不能为空',
          required: true,
          trigger: 'blur'
        }
      ]
    }
  }
}

export default roleModalEditAndAddConfig
